<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
      xmlns:ui="http://java.sun.com/jsf/facelets"
      xmlns:h="http://java.sun.com/jsf/html"
      xmlns:f="http://java.sun.com/jsf/core"
      xmlns:p="http://primefaces.org/ui">

    <ui:composition>

        <p:dialog id="MarcaCreateDlg" widgetVar="MarcaCreateDialog" modal="true" resizable="false" appendToBody="true" header="#{bundle.CreateMarcaTitle}">

            <h:form id="MarcaCreateForm">

                <h:panelGroup id="display">
                    <p:panelGrid columns="2" rendered="#{marcaController.selected != null}">

                        <p:outputLabel value="#{bundle.CreateMarcaLabel_codigo}" for="codigo" />
                        <p:inputText id="codigo" value="#{marcaController.selected.codigo}" title="#{bundle.CreateMarcaTitle_codigo}" required="true" requiredMessage="#{bundle.CreateMarcaRequiredMessage_codigo}"/>

                        <p:outputLabel value="#{bundle.CreateMarcaLabel_descripcion}" for="descripcion" />
                        <p:inputText id="descripcion" value="#{marcaController.selected.descripcion}" title="#{bundle.CreateMarcaTitle_descripcion}" required="true" requiredMessage="#{bundle.CreateMarcaRequiredMessage_descripcion}"/>

                        <p:outputLabel value="#{bundle.CreateMarcaLabel_creationDate}" for="creationDate" />
                        <p:calendar id="creationDate" pattern="MM/dd/yyyy HH:mm:ss" value="#{marcaController.selected.creationDate}" title="#{bundle.EditMarcaTitle_creationDate}" required="true" requiredMessage="#{bundle.EditMarcaRequiredMessage_creationDate}" showOn="button"/>

                        <p:outputLabel value="#{bundle.CreateMarcaLabel_createdBy}" for="createdBy" />
                        <p:inputText id="createdBy" value="#{marcaController.selected.createdBy}" title="#{bundle.CreateMarcaTitle_createdBy}" required="true" requiredMessage="#{bundle.CreateMarcaRequiredMessage_createdBy}"/>

                        <p:outputLabel value="#{bundle.CreateMarcaLabel_lastUpdateDate}" for="lastUpdateDate" />
                        <p:calendar id="lastUpdateDate" pattern="MM/dd/yyyy HH:mm:ss" value="#{marcaController.selected.lastUpdateDate}" title="#{bundle.EditMarcaTitle_lastUpdateDate}"  showOn="button"/>

                        <p:outputLabel value="#{bundle.CreateMarcaLabel_lastUpdateBy}" for="lastUpdateBy" />
                        <p:inputText id="lastUpdateBy" value="#{marcaController.selected.lastUpdateBy}" title="#{bundle.CreateMarcaTitle_lastUpdateBy}" required="true" requiredMessage="#{bundle.CreateMarcaRequiredMessage_lastUpdateBy}"/>
                    </p:panelGrid>
                    <p:commandButton actionListener="#{marcaController.saveNew}" value="#{bundle.Save}" update="display,:MarcaListForm:datalist,:growl" oncomplete="handleSubmit(xhr,status,args,MarcaCreateDialog);"/>
                    <p:commandButton value="#{bundle.Cancel}" onclick="MarcaCreateDialog.hide()"/>
                </h:panelGroup>

            </h:form>

        </p:dialog>

    </ui:composition>

</html>
